#include <iostream>

using namespace std;

class CSizeOfVirtualFunction {
    public:
        virtual void test1 () {
        }
        virtual void test2 () {
        }
        void check () {
        }
};

class CDerived : public CSizeOfVirtualFunction {
    public:
        virtual void test1 () {
        }
        virtual void test2 () {
        }
        virtual void test3 () {
        }
};

class CDerived1 : public CDerived {
    public:
        virtual void test1 () {
        }
        virtual void test2 () {
        }
        virtual void test3 () {
        }
        virtual void test4 () {
        }
};

int main () {
    CSizeOfVirtualFunction svf;
    cout << "sizeof (svf) = " << sizeof (svf) << endl;
    CDerived der;
    cout << "sizeof (der) = " << sizeof (der) << endl;
    CDerived der1;
    cout << "sizeof (der1) = " << sizeof (der1) << endl;
    return 0;
}

